package com.bzm.config;

import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Component;

import lombok.Data;


@Data 
@Component 
public class BzmGlobalConfig{

	@Value("${server.port}") 
    private int port; 
	
	public static final String domain_name  = "http://im.bzmhm.com";
	
	private static final String serverIp = "127.0.0.1";
	
	/**
	 * im 端口 
	 */
    public static int imPort = 8096;
    
    /**
	 * im mq 队列		
	 */
	public static final String im_msg_fanout_queue_mq = "im-msg-fanout-queue-"+6;
    
 
    public String getIP() { 
		/*
		 * InetAddress address = null; try { address = InetAddress.getLocalHost(); }
		 * catch (UnknownHostException e) { return "127.0.0.1-"; }
		 */
        return serverIp+"-"; 
    } 
    
    public String getIPLocalHost() { 
		/*
		 * InetAddress address = null; try { address = InetAddress.getLocalHost(); }
		 * catch (UnknownHostException e) { return "127.0.0.1"; }
		 */
        return serverIp; 
    } 
}
